//判断用户是否登录 
const token = localStorage.getItem('token')
if(token === null){
  window.location.assign('./login.html')
}